import { showTime } from "@/util/tools"
import { ref } from "vue"

export function useTimer() {
  const timeRef = ref("")
  //  处理时间的逻辑

  function fn() {
    timeRef.value = showTime()
    requestAnimationFrame(fn)
  }
  return {
    timeRef,
    fn,
  }
}
